<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        * {
            padding: 0;
            margin: 0;
        }

        .sousuo {
            width: 100%;
            box-sizing: border-box;
            padding: 10px;
        }

        .inputBox {
            width: 100%;
            display: flex;
            margin: 20px 0;
        }

        .inputBox input {
            flex: 1;
            height: 40px;
            border: none;
            outline: none;
            border-radius: 20px;
            background-color: gainsboro;
            padding-left: 20px;
        }

        .inputBox div {
            width: 60px;
            height: 40px;
            text-align: center;
            line-height: 40px;
            color: darkcyan;
            font-size: 18px;
        }

        .find {
            margin-top: 30px;
        }

        span {
            display: inline-block;
            padding: 10px;
            background-color: gainsboro;
            margin-right: 10px;
            margin-top: 20px;
        }
    </style>
</head>

<body>
    <div id="app">
        <div class="sousuo">
            <h3>搜索</h3>

            <div class="inputBox">
                <input type="text" placeholder="搜索商家，商品名称" v-model="searchText">
                <div @click="search">搜索</div>
            </div>


            <div class="block">
                <h4>历史搜索</h4>
                <div class="history">
                    <span v-for="(item,index) in searchArr">{{item}}</span>
                </div>
            </div>

            <div class="find">
                <h4>搜索发现</h4>
                <div class="hotWards">
                    <span v-for="(item,index) in list">{{item}}</span>
                </div>
            </div>

        </div>
    </div>
    <script src="1.vue-2.5.21.js"></script>
    <script src="3.zuoye-搜索.js"></script>
</body>

</html>